package com.softtown.modules.workflow.service;

import com.softtown.common.service.BaseService;
import com.softtown.modules.workflow.dto.SwfLastAprvAddDaPaiDTO;
import com.softtown.modules.workflow.dto.SwfLastAprvReqAddDTO;
import com.softtown.modules.workflow.dto.SwfLastAprvReqDTO;
import com.softtown.modules.workflow.entity.SwfLastAprvReqEntity;

import java.util.List;

/**
 * @author: Dingyayong
 * @Date: 2019/9/23 15:02
 * @Description:
 */
public interface SwfLastAprvReqService extends BaseService<SwfLastAprvReqEntity> {

    /**
     * 根据公司和审批段id 查找出差审批的部门要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    SwfLastAprvReqEntity findLastAprvReqByDeptAndTravel(Long compId, Long phaseId);


    /**
     * 根据公司和审批段id 查找部门要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    SwfLastAprvReqEntity findLastAprvReqByPhaseAndDocType(Long compId, Long phaseId,String docType);

    /**
     * 根据公司和审批段id 查找报销审批的部门要求
     *
     * @param compId
     * @return SwfLastAprvReqEntity
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    SwfLastAprvReqEntity findLastAprvReqByDeptAndExpense(Long compId, Long phaseId);

    /**
     * 根据公司和审批段id,条件为费目来查查找出差审批的岗位要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByItemAndTravel(Long compId, Long phaseId);

    /**
     * 根据公司和审批段id,条件为费目来查查找报销审批的岗位要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByItemAndExpense(Long compId, Long phaseId);
    /**
     * 根据公司和审批段要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByReqAndCondType(Long compId,String docTypeValue, Long phaseId,String reqType,String condType);

    /**
     * 根据公司和审批段id,条件为金额来查查找出差审批的岗位要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByMoneyAndTravel(Long compId, Long phaseId);

    /**
     * 根据公司和审批段id,条件为金额来查查找报销审批的岗位要求
     *
     * @param
     * @return
     * @author Dingyayong
     * @date 2019/9/23 15:07
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByMoneyAndExpense(Long compId, Long phaseId);

    /**
     * 添加最终审设置
     *
     * @param swfLastAprvReqAddDTOList
     * @return
     * @author Dingyayong
     * @date 2019/9/26 18:06
     */
    void addSwfLastAprvReq(SwfLastAprvReqAddDTO swfLastAprvReqAddDTOList);

    /**
     * 根据公司和单据类型,来获取审批段设置
     *
     * @param compId docTypeValue
     * @return
     * @author Dingyayong
     * @date 2019/9/26 18:06
     */
    SwfLastAprvReqAddDTO getSwfLastAprvReqInfo(Long compId, String docTypeValue);

    /**
     * 根据公司和审批段id查找借款审批的部门要求
     *
     * @param compId
     * @param phaseId
     * @return com.softtown.modules.entity.SwfLastAprvReqEntity
     * @author fuming
     * @date 2019/10/30 15:00
     */
    SwfLastAprvReqEntity findLastAprvReqByDeptAndAdv(Long compId, Long phaseId);

    /**
     * 根据公司和审批段id条件为费目来查找借款审批的岗位要求
     *
     * @param compId
     * @param phaseId
     * @return java.util.List<com.softtown.modules.entity.SwfLastAprvReqEntity>
     * @author fuming
     * @date 2019/10/30 15:05
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByItemAndAdv(Long compId, Long phaseId);

    /**
     * 根据公司和审批段id条件为金额来查找借款审批的岗位要求
     *
     * @param compId
     * @param phaseId
     * @return java.util.List<com.softtown.modules.entity.SwfLastAprvReqEntity>
     * @author fuming
     * @date 2019/10/30 15:10
     */
    List<SwfLastAprvReqEntity> findLastAprvReqByMoneyAndAdv(Long compId, Long phaseId);

    /**
     * 修改最终审设置
     *
     * @param swfLastAprvReqAddDTOList
     * @return
     * @author Dingyayong
     * @date 2019/9/26 18:06
     */
    void editSwfLastAprvReq(SwfLastAprvReqAddDTO swfLastAprvReqAddDTOList);

    /**
     * 删除最终审设置
     *
     * @param swfLastAprvReqDTO SwfLastAprvReqDTO
     * @return
     * @author Dingyayong
     * @date 2019/9/26 18:06
     */
    void deleteSwfLastAprvReq(SwfLastAprvReqDTO swfLastAprvReqDTO);


    void addDaPaiAprvReq(SwfLastAprvAddDaPaiDTO swfLastAprvAddDaPaiDTO);
    void editDaPaiAprvReq(SwfLastAprvAddDaPaiDTO swfLastAprvAddDaPaiDTO);
    void deleteDaPaiAprvReq(SwfLastAprvAddDaPaiDTO swfLastAprvAddDaPaiDTO);

    SwfLastAprvAddDaPaiDTO getDaPaiAprvReqInfo(Long compId, String docTypeValue);
}
